@model ToDoListWeb.Models.UserModel
@section head{
<link href="~/css/_Layout/mainMenu.css" rel="stylesheet" />
}
@{
}
<div id="body-display">
    <div id="left-top">
        <form class="pull-down-form" id="pull-down-form" onkeydown="if(event.keyCode==13){return false;}">
            
        </form>
        <div id="left-top-title" class="display-title">
            <script src="~/js/sharedAjax.js"></script>
            <p>清单列表<a id="a-add" onclick="createType()"><img id="img-add" src="~/images/添加.png" alt=""></a></p>
        </div>
        <div class="scroll">
            <div id="inventorys" class="type-div">
                @if (Model.Type != null)
                {
                    foreach (var item in Model.Type)
                    {
                        <div class="type">
                            <h5 class="type-title" onclick="pullDown(@(item.TypeName+item.TypeId))">@item.TypeName</h5>
                            <div class="type-menu" id=@item.TypeName onclick="clearButton(@item.TypeName,@item.TypeId)">······</div>
                        </div>
                        <ul id=@(item.TypeName+item.TypeId) class="typeName">
                            @if (Model.Inventory != null)
                            {
                                @foreach (var inv in Model.Inventory.Where(i => i.TypeId == item.TypeId).ToList())
                                {
                                    <li>
                                        <a id="a-inventory" class="a-inventory-name" onclick="chooseInventory(@inv.InventoryId)">
                                            <span>@inv.InventoryName</span>
                                        </a>
                                        <a id="a-delete" onclick="deleteInventory(@inv.InventoryId)"><img src="~/images/删除.png" id="delete-img"></a>
                                        <a id="a-compile" href="/Inventory/CompileInventoryView?inventoryId=@inv.InventoryId"><img id="compile-img-inventory" src="~/images/编辑.png"></a>
                                    </li>
                                }
                            }
                        </ul>
                    }
                }
            </div>
        </div>
    </div>
    <div id="right-top">
        <div id="right-top-title" class="display-title">
            <p>事项列表</p>
            <a id="a-add-matter" onclick="addMatter()"><img id="img-add" src="~/images/添加.png" alt=""></a>
        </div>
        <div class="scroll" id="right-top-content">
        </div>
    </div>
    <div id="left-bottom">
        <div id="left-bottom-title" class="display-title">
            <p id="matter-content">事项内容</p>
            <a id="a-compile-matter" href="/Matter/CompileMatterView?matterId=0"><img id="compile-img-matter" src="~/images/编辑.png"></a>
            <span id="matter-date"><span onclick="getDetailMatter(0)"><img id="detail" src="~/images/详细.png"></span></span>
        </div>
        <div class="scroll" id="show-matter-content">
        </div>
    </div>
    <div id="right-bottom">
        <div id="right-bottom-title" class="display-title">
            <p id="matter-content">事项备注</p>
        </div>
        <div class="scroll" id="show-matter-remark">
        </div>
    </div>
</div>
<script src="~/js/sharedAjax.js"></script>